<template>
  <div class="right-view-ZQCX001" ref="viewBox">
    <div class="seckill-component" id="seckill-component">
      <div class="app-header-nav">
        首页封面
      </div>
      <div class="content-box" ref="coverPictures">
        <div class="top-box"></div>

        <!--          <div class="title-box">-->
        <!--            <div class="title-box-text">活动内容</div>-->
        <!--          </div>-->
        <!--          <div class="content-box-item">-->
        <!--            {{seckilData.activityContent|appData('activityContent')}}-->
        <!--          </div>-->
        <div class="yhq-btn">查看详情</div>
      </div>
      <!--      <div class="app-header-nav">-->
      <!--        活动列表-->
      <!--      </div>-->
      <!--      <div cLass="list-box">-->
      <!--        <div class="left-box" ref="listPictures">-->
      <!--        </div>-->
      <!--        <div class="right-box">-->
      <!--          <div class="titles">{{seckilData.activityName|appData('activityName')}}</div>-->
      <!--          <div class="time">{{seckilData.startTime||'2022.06.30'}}-{{seckilData.endTime||'2022.07.30'}}</div>-->
      <!--          <div class="type">节日活动</div>-->
      <!--        </div>-->
      <!--      </div>-->
    </div>
  </div>
</template>

<script>


let defaultData = {
  activityName: "超值立减金限时大放送",
  activityContent: "中秋活动正式开启，福利特惠面向全体用户， xx优惠券/特惠车型限时领取/秒杀"
}
export default {
  name: 'SeckillMobile',
  props: {
    seckilData: {
      activityName: {
        type: String,
        default() {
          return '0'
        },
      },
      activityContent: {
        type: String,
        default() {
          return '0'
        },
      },
      activityUnit: {
        type: Array,
        default() {
          return [{
            applicableUnit: "西安市高新科技园店",
            unitAddress: "西安市雁塔区GOGO街区"
          }]
        }
      }
    },
    goodsList: {
      type: Array,
      default() {
        return []
      },
    },
  },
  filters: {
    appData(val, key) {
      if (val && val != '') {
        return val
      } else {
        return defaultData[key]
      }
    }
  },

  data() {
    return {

    }
  },
  mounted() {
    // js

    this.zoom()
    // 窗口大小变化时，需要重算
    window.addEventListener('resize', this.zoom, false)
  },
  methods: {
    zoom() {
      let domBody = document.getElementsByClassName('right-view-ZQCX001')[0]
      domBody.style.zoom = document.body.clientWidth / 22 + '%'
    }
  },
  destroyed() {
    window.removeEventListener('resize', this.zoom, false)
  },
}
</script>

<style scoped>
.seckill-component {
  background: #ededed;

  width: 374px;
  height: 735px;
  font-size: 12px;
  margin: 0 auto;

}

.yhq-title {
  height: 232px;
  width: 100%;
  font-size: 104px;
  line-height: 110px;
  font-style: italic;
  font-weight: 600;
  color: #FFFFFF;
  text-shadow: 12px 6px red;
  padding: 120px 60px;
  text-align: center;
}

.app-header-nav {
  text-align: center;
  line-height: 40px;
  font-size: 20px;
}

.list-box {
  width: 339.5px;
  height: 120px;
  background: #ffffff;
  border-radius: 8px;
  margin: auto;
  display: flex;
}

.list-box .titles {
  font-size: 15px;
  font-weight: bold;
  text-align: right;
  color: #333333;
  line-height: 23px;
  letter-spacing: 0.38px;
  overflow: hidden;
  text-overflow: ellipsis;
  word-wrap: break-word;
  white-space: normal !important;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  height: 50px;
}

.list-box .time {
  width: 147px;
  height: 22px;
  background: #ececec;
  border-radius: 2px;
  text-align: right;
  line-height: 22px;
  position: relative;
  right: -8px;
}

.list-box .type {
  font-size: 12px;
  font-weight: bold;
  text-align: right;
  color: #999999;
  letter-spacing: 0.3px;
  line-height: 30px;
}

.left-box {
  width: 642px;
  height: 480px;
  background-image: url(./img/list.png);
  background-size: 100% 100%;
  zoom: 0.25;
}

.right-box {
  height: 120px;
  width: 179px;
  padding: 12px;
  text-align: end;
}

.right-view-ZQCX001 {
  background: #ffffff;
  width: 433px;
  height: 865px;
  font-size: 12px;
  margin: 0 auto;
  background-image: url(../../../commImg/phone/left.png), url(../../../commImg/phone/top.png), url(../../../commImg/phone/right.png), url(../../../commImg/phone/lower.png);
  background-repeat: no-repeat, no-repeat, no-repeat, no-repeat;
  background-position: left bottom, top, right bottom, bottom;
  padding: 65px 30px 59px 30px;
}

::-webkit-scrollbar {
  width: 0 !important;
}

::-webkit-scrollbar {
  width: 0 !important;
  height: 0;
}

.left-box-yhq-title {
  font-size: 72px;
  /* padding: 20px; */
  margin: 40px auto;
  width: 420px;
  text-align: center;
  font-style: italic;
  font-weight: 600;
  color: #FFFFFF;
  text-shadow: 8px 4px red;
}

.content-box {
  width: 700px;
  height: 1370px;
  /*background-image: url(./img/yhqbg1.png);*/
  /*background-size: 100% 150%;*/
  padding-bottom: 80px;
  background: linear-gradient(0deg, #ff9045 0%, #ff8a00 100%);
  margin: 0 auto;
  border-radius: 16px;
  zoom: 0.5;
  position: relative;
}

.yhq-btn {
  width: 420px;
  height: 84px;
  border: 2px solid #ededed;
  border-radius: 10px;
  font-size: 35px;
  color: #ffffff;
  text-align: center;
  line-height: 80px;
  position: absolute;
  bottom: 100px;
  left: 140px;
}

.top-box {
  width: 100%;
  height: 486px;
  background-image: url(./img/topBg.png);
  background-repeat: no-repeat;
  background-size: 100% 100.5%;
  margin: auto;
}

.title-box {
  width: 665px;
  height: 152px;
  z-index: 2;
  background-image: url(./img/titleBg.png);
  background-repeat: no-repeat;
  background-size: 100.2% 101%;
  position: relative;
  margin: auto;
}

.title-box-text {
  margin-left: 110px;
  font-size: 36px;
  font-weight: bold;
  color: #333333;
  position: relative;
  top: 36px;
}

.content-box-item {
  width: 665px;
  border: 3px solid #1c1c1c;
  border-top: none;
  border-radius: 8px;
  position: relative;
  top: -61px;
  background: #f1f3f2;
  z-index: 1;
  margin: auto;
  padding: 30px 37px 20px 37px;
  font-size: 28px;
  font-weight: bold;
  text-align: left;
  color: #666666;
  line-height: 44px;
  letter-spacing: 0.28px;
  word-break: break-all;
}
</style>
